package com.cgm.rsp.internal;

import java.util.HashMap;
import java.util.Map;

import javax.ws.rs.ApplicationPath;
import javax.ws.rs.core.MediaType;

import com.sun.jersey.api.core.PackagesResourceConfig;
import com.sun.jersey.api.json.JSONConfiguration;


@ApplicationPath(value = "/")
public class InternalApplication extends PackagesResourceConfig {
	public InternalApplication() {
		super("com.cgm.rsp.internal");
		
	    getMediaTypeMappings().put("json", MediaType.APPLICATION_JSON_TYPE);
	    getMediaTypeMappings().put("xml", MediaType.APPLICATION_XML_TYPE);
	    
	    Map<String,Object> params=new HashMap<String, Object>();
	    params.put(JSONConfiguration.FEATURE_POJO_MAPPING, Boolean.TRUE);
	    //params.put(FreemarkerViewProcessor.FREEMARKER_TEMPLATES_BASE_PATH, "freemarker");
	    
	    setPropertiesAndFeatures(params);
	}

}
